<!DOCTYPE html>
<html class="client-nojs vector-feature-language-in-header-enabled vector-feature-language-in-main-page-header-disabled vector-feature-page-tools-pinned-disabled vector-feature-toc-pinned-clientpref-0 vector-toc-not-available vector-feature-main-menu-pinned-disabled vector-feature-limited-width-clientpref-1 vector-feature-limited-width-content-enabled vector-feature-custom-font-size-clientpref-1 vector-feature-appearance-pinned-clientpref-0 skin-theme-clientpref-day vector-sticky-header-enabled" lang="de" dir="ltr"><head>
<meta charset="UTF-8">
<title>Cipher Block Chaining Mode</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="icon" type="image/png" href="./_res_/favicon.png">
<link rel="canonical" href="https://de.wikipedia.org/wiki/Cipher_Block_Chaining_Mode"> <link href="./_mw_/ext.cite.styles.css" rel="stylesheet" type="text/css">
<link href="./_mw_/ext.math.styles.css" rel="stylesheet" type="text/css">
<link href="./_mw_/ext.wikimediamessages.styles.css" rel="stylesheet" type="text/css">
<link href="./_mw_/skins.vector.icons.css" rel="stylesheet" type="text/css">
<link href="./_mw_/skins.vector.search.codex.styles.css" rel="stylesheet" type="text/css">
<link href="./_mw_/skins.vector.styles.css" rel="stylesheet" type="text/css">
<meta name="ResourceLoaderDynamicStyles" content="">
<link href="./_mw_/ext.gadget.citeRef.css" rel="stylesheet" type="text/css">
<link href="./_mw_/ext.gadget.defaultPlainlinks.css" rel="stylesheet" type="text/css">
<link href="./_mw_/ext.gadget.dewikiCommonHide.css" rel="stylesheet" type="text/css">
<link href="./_mw_/ext.gadget.dewikiCommonLayout.css" rel="stylesheet" type="text/css">
<link href="./_mw_/ext.gadget.dewikiCommonStyle.css" rel="stylesheet" type="text/css">
<link href="./_mw_/ext.gadget.dewikiDarkmode.css" rel="stylesheet" type="text/css">
<link href="./_mw_/ext.gadget.dewikiResponsive.css" rel="stylesheet" type="text/css">
<link href="./_mw_/ext.gadget.specialSearch.css" rel="stylesheet" type="text/css">
<link rel="stylesheet" type="text/css" href="./_mw_/site.styles.css">
<link rel="stylesheet" type="text/css" href="./_mw_/noscript.css">
<link rel="stylesheet" type="text/css" href="./_res_/footer.css">
<link rel="stylesheet" type="text/css" href="./_res_/vector-2022.css">
</head>
<body class="skin--responsive skin-vector skin-vector-search-vue mediawiki ltr sitedir-ltr mw-hide-empty-elt ns-0 ns-subject page-Cipher_Block_Chaining_Mode rootpage-Cipher_Block_Chaining_Mode skin-vector-2022 action-view">
<div class="mw-page-container">
<div class="mw-page-container-inner">
<div class="mw-content-container">
<main id="content" class="mw-body">
<header class="mw-body-header vector-page-titlebar">
<h1 id="firstHeading" class="firstHeading mw-first-heading"><span class="mw-page-title-main">Cipher Block Chaining Mode</span></h1>
</header>
<a id="top"></a>
<div id="bodyContent" class="vector-body ve-init-mw-desktopArticleTarget-targetContainer" aria-labelledby="firstHeading" data-mw-ve-target-container="">
<div id="contentSub">
<div id="mw-content-subtitle"></div>
</div>
<div id="mw-content-text" class="mw-body-content mw-content-ltr" lang="de" dir="ltr"><div class="mw-content-ltr mw-parser-output" lang="de" dir="ltr"><p><b>Cipher Block Chaining Mode</b> (<b>CBC Mode</b>) ist eine <a href="Betriebsmodus_(Kryptographie)" title="Betriebsmodus (Kryptographie)">Betriebsart</a>, in der <a href="Blockchiffre" class="mw-redirect" title="Blockchiffre">Blockchiffren</a> betrieben werden können. Vor dem Verschlüsseln eines <a href="Klartext_(Kryptographie)" title="Klartext (Kryptographie)">Klartextblocks</a> wird dieser zunächst mit dem im vorhergehenden Schritt erzeugten <a href="Geheimtext" title="Geheimtext">Geheimtextblock</a> per <a href="XOR" class="mw-redirect" title="XOR">XOR</a> (exklusives Oder) verknüpft. Der Modus wurde 1976 von William F. Ehrsam, Carl H. W. Meyer, John L. Smith und Walter L. Tuchman veröffentlicht.<sup id="cite_ref-1" class="reference"><a href="#cite_note-1"><span class="cite-bracket">[</span>1<span class="cite-bracket">]</span></a></sup>
</p>
<div class="mw-heading mw-heading2"><h2 id="Allgemeines">Allgemeines</h2></div>
<p>Die Struktur der Verschlüsselung im CBC-Modus ist in nachfolgender Abbildung dargestellt:
</p><p><span class="mw-default-size" typeof="mw:File"></span>
</p><p>Man kann dieses Diagramm auch mathematisch in Formeln ausdrücken, bezeichne dazu <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle E_{K}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>E</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>K</mi>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle E_{K}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/af0a6dea578749bf4471c1e2f1fc29d110aec491.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:3.408ex; height:2.509ex;" alt="{\displaystyle E_{K}}" loading="lazy"></span> die Verschlüsselungsfunktion mit dem Schlüssel <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle K}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<mi>K</mi>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle K}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/2b76fce82a62ed5461908f0dc8f037de4e3686b0.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.338ex; width:2.066ex; height:2.176ex;" alt="{\displaystyle K}" loading="lazy"></span>, sei <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle D_{K}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>D</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>K</mi>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle D_{K}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/24d388ffc0bf7da5a4d0648d6e2160c09fe1171d.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:3.617ex; height:2.509ex;" alt="{\displaystyle D_{K}}" loading="lazy"></span> die zugehörige
Entschlüsselungsfunktion. Bezeichne <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle P_{i}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>P</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle P_{i}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/3ba1396129f7be3c7f828a571b6649e6807d10d3.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.292ex; height:2.509ex;" alt="{\displaystyle P_{i}}" loading="lazy"></span> den i-ten Klartextblock, <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle C_{i}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle C_{i}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/cc49dc02c0ec8c86b67e7d10518ac791eda0bf22.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.461ex; height:2.509ex;" alt="{\displaystyle C_{i}}" loading="lazy"></span> den i-ten Geheimtextblock und sei <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle IV}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<mi>I</mi>
<mi>V</mi>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle IV}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/05e02bc314180f8770fd135cd0e80ac4835a676d.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.338ex; width:2.959ex; height:2.176ex;" alt="{\displaystyle IV}" loading="lazy"></span> der Initialisierungsvektor; in der Regel wird <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle C_{0}=IV}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>0</mn>
</mrow>
</msub>
<mo>=</mo>
<mi>I</mi>
<mi>V</mi>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle C_{0}=IV}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/7b8cee079a821cf0a25744655bd839d122716b73.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:8.773ex; height:2.509ex;" alt="{\displaystyle C_{0}=IV}" loading="lazy"></span> definiert. Außerdem bezeichne <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle \oplus }">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<mo>⊕<!-- ⊕ --></mo>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle \oplus }</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/8b16e2bdaefee9eed86d866e6eba3ac47c710f60.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.505ex; width:1.808ex; height:2.176ex;" alt="{\displaystyle \oplus }" loading="lazy"></span> das logische XOR.
Dann ist die Verschlüsselung im CBC-Modus wie folgt <a href="Rekursiv" class="mw-redirect" title="Rekursiv">rekursiv</a> definiert:
</p><p><span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle \forall i\in \mathbb {N} ^{+}:C_{i}=E_{K}(P_{i}\oplus C_{i-1})}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<mi mathvariant="normal">∀<!-- ∀ --></mi>
<mi>i</mi>
<mo>∈<!-- ∈ --></mo>
<msup>
<mrow class="MJX-TeXAtom-ORD">
<mi mathvariant="double-struck">N</mi>
</mrow>
<mrow class="MJX-TeXAtom-ORD">
<mo>+</mo>
</mrow>
</msup>
<mo>:</mo>
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
</mrow>
</msub>
<mo>=</mo>
<msub>
<mi>E</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>K</mi>
</mrow>
</msub>
<mo stretchy="false">(</mo>
<msub>
<mi>P</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
</mrow>
</msub>
<mo>⊕<!-- ⊕ --></mo>
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
<mo>−<!-- − --></mo>
<mn>1</mn>
</mrow>
</msub>
<mo stretchy="false">)</mo>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle \forall i\in \mathbb {N} ^{+}:C_{i}=E_{K}(P_{i}\oplus C_{i-1})}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/e172a3b0d40addcf2cf5225cef7a2c61c295c68f.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.838ex; width:30.534ex; height:3.009ex;" alt="{\displaystyle \forall i\in \mathbb {N} ^{+}:C_{i}=E_{K}(P_{i}\oplus C_{i-1})}" loading="lazy"></span>
</p><p>Die Struktur der Entschlüsselung im CBC-Modus ist in nachfolgender Abbildung dargestellt:
</p><p><span class="mw-default-size" typeof="mw:File"></span>
</p><p>Die zugehörige Entschlüsselung ist im CBC-Modus hingegen nicht rekursiv und lautet mit den gleichen Bezeichnungen wie oben:
</p><p><span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle \forall i\in \mathbb {N} ^{+}:P_{i}=D_{K}(C_{i})\oplus C_{i-1}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<mi mathvariant="normal">∀<!-- ∀ --></mi>
<mi>i</mi>
<mo>∈<!-- ∈ --></mo>
<msup>
<mrow class="MJX-TeXAtom-ORD">
<mi mathvariant="double-struck">N</mi>
</mrow>
<mrow class="MJX-TeXAtom-ORD">
<mo>+</mo>
</mrow>
</msup>
<mo>:</mo>
<msub>
<mi>P</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
</mrow>
</msub>
<mo>=</mo>
<msub>
<mi>D</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>K</mi>
</mrow>
</msub>
<mo stretchy="false">(</mo>
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
</mrow>
</msub>
<mo stretchy="false">)</mo>
<mo>⊕<!-- ⊕ --></mo>
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
<mo>−<!-- − --></mo>
<mn>1</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle \forall i\in \mathbb {N} ^{+}:P_{i}=D_{K}(C_{i})\oplus C_{i-1}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/3e7d242dd3de2ec89c240c0fe0a687cc8fa506be.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.838ex; width:30.743ex; height:3.009ex;" alt="{\displaystyle \forall i\in \mathbb {N} ^{+}:P_{i}=D_{K}(C_{i})\oplus C_{i-1}}" loading="lazy"></span>
</p><p>Als <a href="Initialisierungsvektor" title="Initialisierungsvektor">Initialisierungsvektor</a> (IV) benutzt man entweder einen <a href="Zeitstempel" title="Zeitstempel">Zeitstempel</a> oder eine zufällige Zahlenfolge.
Manche Anwendungen benutzen auch eine vorhersagbare, einfach aufsteigende Zahl, aber dies ist nicht sicher, weil fremde Personen unerwünscht einen <a href="Wasserzeichenangriff" title="Wasserzeichenangriff">Wasserzeichenangriff</a> (<i>watermark attack</i>) auf solche Daten ausführen können.
Das Modul <a href="Dm-crypt" title="Dm-crypt">dm-crypt</a> benutzt zur Generierung des IV das <a href="ESSIV" title="ESSIV">ESS</a>-Verfahren.
</p><p>Für die Sicherheit des <a href="Algorithmus" title="Algorithmus">Algorithmus</a> ist es nicht notwendig, den <a href="Initialisierungsvektor" title="Initialisierungsvektor">Initialisierungsvektor</a> geheim zu übertragen.
</p><p>Der CBC-Mode hat einige wichtige Vorteile:
</p>
<ul><li>Klartextmuster werden zerstört.</li>
<li>Identische Klartextblöcke ergeben unterschiedliche Geheimtexte.</li>
<li>Verschiedene Angriffe (Time-Memory-Tradeoff und Klartextangriffe) werden erschwert.</li>
<li>Eine Umsortierung von Chiffratblöcken führt zu fehlerhaften Klartextblöcken.</li></ul>
<p>Jedoch hat der CBC-Mode auch einige Nachteile:
</p>
<ul><li>Die Verschlüsselung ist nicht parallelisierbar, da <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle C_{i-1}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
<mo>−<!-- − --></mo>
<mn>1</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle C_{i-1}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/06345a9bc7748c399649cdef52231df3f9095eb3.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:4.562ex; height:2.509ex;" alt="{\displaystyle C_{i-1}}" loading="lazy"></span> bekannt sein muss, aber sehr wohl die Entschlüsselung.</li>
<li>Bitfehler im Chiffrat multiplizieren sich beim Entschlüsseln im Klartext.</li>
<li>Das Chiffrat ist veränderbar und annähernd XOR-homomorph.<sup id="cite_ref-2" class="reference"><a href="#cite_note-2"><span class="cite-bracket">[</span>2<span class="cite-bracket">]</span></a></sup></li></ul>
<p>Da ein Geheimtextblock nur von dem vorherigen Block abhängt, verursacht ein beschädigter Geheimtextblock, wie beispielsweise ein Bitfehler bei der Datenübertragung, beim Entschlüsseln keinen allzu großen Schaden: Der Klartextblock <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle P_{i}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>P</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle P_{i}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/3ba1396129f7be3c7f828a571b6649e6807d10d3.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.292ex; height:2.509ex;" alt="{\displaystyle P_{i}}" loading="lazy"></span> wird zerstört und im Klartextblock <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle P_{i+1}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>P</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
<mo>+</mo>
<mn>1</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle P_{i+1}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/f136f56b4622ba295774deff5319b5b773c0c88c.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:4.392ex; height:2.509ex;" alt="{\displaystyle P_{i+1}}" loading="lazy"></span> wird das respektive Bit negiert. Dies ist unmittelbar aus der Definition der Entschlüsselung und obiger Abbildung ersichtlich, da ein beschädigter Geheimtextblock <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle C_{i}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle C_{i}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/cc49dc02c0ec8c86b67e7d10518ac791eda0bf22.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.461ex; height:2.509ex;" alt="{\displaystyle C_{i}}" loading="lazy"></span> nur die Klartextblöcke <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle P_{i}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>P</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle P_{i}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/3ba1396129f7be3c7f828a571b6649e6807d10d3.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.292ex; height:2.509ex;" alt="{\displaystyle P_{i}}" loading="lazy"></span> und <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle P_{i+1}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>P</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
<mo>+</mo>
<mn>1</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle P_{i+1}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/f136f56b4622ba295774deff5319b5b773c0c88c.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:4.392ex; height:2.509ex;" alt="{\displaystyle P_{i+1}}" loading="lazy"></span> beeinflusst und sich nicht unbeschränkt weiter verbreitet. Trotzdem kann diese beschränkte Vervielfachung nur eines einzigen Bitfehlers im <a href="Chiffrat" class="mw-redirect" title="Chiffrat">Chiffrat</a> bei CBC eine <a href="Vorw%C3%A4rtsfehlerkorrektur" title="Vorwärtsfehlerkorrektur">Vorwärtsfehlerkorrektur</a> des Klartextes erschweren bzw. unmöglich machen. Genauso verursacht ein beschädigter Initialisierungsvektor beim Entschlüsseln keinen allzu großen Schaden, da dadurch nur der Klartextblock <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle P_{1}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>P</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle P_{1}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/398f438d75434e6fbf48dc232c1ad7228a738568.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.547ex; height:2.509ex;" alt="{\displaystyle P_{1}}" loading="lazy"></span> beschädigt wird.
</p><p>Der CBC-Modus ist wesentlich sicherer als der <a href="Electronic_Code_Book_Mode" title="Electronic Code Book Mode">ECB</a>-Modus, vor allem wenn man <i>keine</i> zufälligen Texte hat. Unsere Sprache und andere Dateien, wie z. B. Video-Dateien, sind keinesfalls zufällig, weswegen der ECB-Mode gefährlich ist.
</p>
<div class="mw-heading mw-heading2"><h2 id="Beispiel">Beispiel</h2></div>
<dl><dt>Klartext</dt>
<dd>01 10</dd>
<dt>Aufgeteilt in Blöcke</dt>
<dd>01 = <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle B_{1}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>B</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle B_{1}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/1fa091eb428443c9c5c5fcf32a69d3665c89e00c.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.818ex; height:2.509ex;" alt="{\displaystyle B_{1}}" loading="lazy"></span>, 10 = <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle B_{2}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>B</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle B_{2}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/199944d59dcc18842dfd1deab6000a1d1dadcbae.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.818ex; height:2.509ex;" alt="{\displaystyle B_{2}}" loading="lazy"></span></dd>
<dt>Schlüssel</dt>
<dd>11=k</dd>
<dt>Init. Vektor (IV)</dt>
<dd>01</dd></dl>
<p>Zur Vereinfachung wird als Verschlüsselungsfunktion <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle E}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<mi>E</mi>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle E}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/4232c9de2ee3eec0a9c0a19b15ab92daa6223f9b.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.338ex; width:1.776ex; height:2.176ex;" alt="{\displaystyle E}" loading="lazy"></span> die <a href="Dualsystem#Grundrechenarten_im_Dualsystem" title="Dualsystem">binäre Addition</a> und als Entschlüsselungsfunktion <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle D}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<mi>D</mi>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle D}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/f34a0c600395e5d4345287e21fb26efd386990e6.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.338ex; width:1.924ex; height:2.176ex;" alt="{\displaystyle D}" loading="lazy"></span> die binäre Subtraktion verwendet.
</p>
<div class="mw-heading mw-heading3"><h3 id="Verschlüsselung"><span id="Verschl.C3.BCsselung"></span>Verschlüsselung</h3></div>
<p>Block 1:
</p>
<ul><li><span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle B_{1}\oplus IV=01\oplus 01=00=C_{1}'}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>B</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
</msub>
<mo>⊕<!-- ⊕ --></mo>
<mi>I</mi>
<mi>V</mi>
<mo>=</mo>
<mn>01</mn>
<mo>⊕<!-- ⊕ --></mo>
<mn>01</mn>
<mo>=</mo>
<mn>00</mn>
<mo>=</mo>
<msubsup>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
<mo>′</mo>
</msubsup>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle B_{1}\oplus IV=01\oplus 01=00=C_{1}'}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/52b3a8dc68bf3182c2556fcae85f8dbaa0f9f2fd.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -1.005ex; width:30.444ex; height:2.843ex;" alt="{\displaystyle B_{1}\oplus IV=01\oplus 01=00=C_{1}'}" loading="lazy"></span></li>
<li><span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle E_{k}(C_{1}')=C_{1}'+k=00+11=11=C_{1}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>E</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>k</mi>
</mrow>
</msub>
<mo stretchy="false">(</mo>
<msubsup>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
<mo>′</mo>
</msubsup>
<mo stretchy="false">)</mo>
<mo>=</mo>
<msubsup>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
<mo>′</mo>
</msubsup>
<mo>+</mo>
<mi>k</mi>
<mo>=</mo>
<mn>00</mn>
<mo>+</mo>
<mn>11</mn>
<mo>=</mo>
<mn>11</mn>
<mo>=</mo>
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle E_{k}(C_{1}')=C_{1}'+k=00+11=11=C_{1}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/ceaec9fe4d774b470da590103e89ab871a250a11.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -1.005ex; width:39.022ex; height:3.009ex;" alt="{\displaystyle E_{k}(C_{1}')=C_{1}'+k=00+11=11=C_{1}}" loading="lazy"></span></li></ul>
<p>Block 2:
</p>
<ul><li><span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle B_{2}\oplus C_{1}=10\oplus 11=01=C_{2}'}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>B</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
</msub>
<mo>⊕<!-- ⊕ --></mo>
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
</msub>
<mo>=</mo>
<mn>10</mn>
<mo>⊕<!-- ⊕ --></mo>
<mn>11</mn>
<mo>=</mo>
<mn>01</mn>
<mo>=</mo>
<msubsup>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
<mo>′</mo>
</msubsup>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle B_{2}\oplus C_{1}=10\oplus 11=01=C_{2}'}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/c92ed62f7a7e4d0186166f7e68b0bd19df731a83.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -1.005ex; width:30.201ex; height:2.843ex;" alt="{\displaystyle B_{2}\oplus C_{1}=10\oplus 11=01=C_{2}'}" loading="lazy"></span></li>
<li><span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle E_{k}(C_{2}')=C_{2}'+k=01+11=00=C_{2}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>E</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>k</mi>
</mrow>
</msub>
<mo stretchy="false">(</mo>
<msubsup>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
<mo>′</mo>
</msubsup>
<mo stretchy="false">)</mo>
<mo>=</mo>
<msubsup>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
<mo>′</mo>
</msubsup>
<mo>+</mo>
<mi>k</mi>
<mo>=</mo>
<mn>01</mn>
<mo>+</mo>
<mn>11</mn>
<mo>=</mo>
<mn>00</mn>
<mo>=</mo>
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle E_{k}(C_{2}')=C_{2}'+k=01+11=00=C_{2}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/3f708d8eb5383e0cce369f53f7cdde6fd7690cc3.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -1.005ex; width:39.022ex; height:3.009ex;" alt="{\displaystyle E_{k}(C_{2}')=C_{2}'+k=01+11=00=C_{2}}" loading="lazy"></span></li></ul>
<p>Verschlüsselter Text:
</p>
<ul><li><span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle C_{1}C_{2}=1100}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
</msub>
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
</msub>
<mo>=</mo>
<mn>1100</mn>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle C_{1}C_{2}=1100}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/5ffa9caa0320521dfc6ececb09401668d1885080.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:13.18ex; height:2.509ex;" alt="{\displaystyle C_{1}C_{2}=1100}" loading="lazy"></span></li></ul>
<p>Betrachtet man die Verschlüsselung von <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle B_{2}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>B</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle B_{2}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/199944d59dcc18842dfd1deab6000a1d1dadcbae.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.818ex; height:2.509ex;" alt="{\displaystyle B_{2}}" loading="lazy"></span>, sieht man, dass dazu <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle C_{1}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle C_{1}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/babf569931f1a7b5182b9bec51873c2f5692fbb8.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.716ex; height:2.509ex;" alt="{\displaystyle C_{1}}" loading="lazy"></span> benötigt wird. Generell bedeutet das, dass für eine Verschlüsselung von <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle B_{i}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>B</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle B_{i}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/82cda0578ec6b48774c541ecb9bee4a90176e62f.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.564ex; height:2.509ex;" alt="{\displaystyle B_{i}}" loading="lazy"></span> der Chiffratblock <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle C_{i-1}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
<mo>−<!-- − --></mo>
<mn>1</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle C_{i-1}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/06345a9bc7748c399649cdef52231df3f9095eb3.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:4.562ex; height:2.509ex;" alt="{\displaystyle C_{i-1}}" loading="lazy"></span> benötigt wird. Eine Parallelisierung des Verschlüsselungsvorgangs fällt damit aus.
</p>
<div class="mw-heading mw-heading3"><h3 id="Entschlüsselung"><span id="Entschl.C3.BCsselung"></span>Entschlüsselung</h3></div>
<p>Block 1:
</p>
<ul><li><span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle D_{k}(C_{1})=C_{1}-k=11-11=00=C_{1}'}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>D</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>k</mi>
</mrow>
</msub>
<mo stretchy="false">(</mo>
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
</msub>
<mo stretchy="false">)</mo>
<mo>=</mo>
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
</msub>
<mo>−<!-- − --></mo>
<mi>k</mi>
<mo>=</mo>
<mn>11</mn>
<mo>−<!-- − --></mo>
<mn>11</mn>
<mo>=</mo>
<mn>00</mn>
<mo>=</mo>
<msubsup>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
<mo>′</mo>
</msubsup>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle D_{k}(C_{1})=C_{1}-k=11-11=00=C_{1}'}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/b9deb2e9cc4c5c0d1b84a9d39a196fb0780d4d95.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -1.005ex; width:39.231ex; height:3.009ex;" alt="{\displaystyle D_{k}(C_{1})=C_{1}-k=11-11=00=C_{1}'}" loading="lazy"></span></li>
<li><span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle C_{1}'\oplus IV=00\oplus 01=01=B_{1}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msubsup>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
<mo>′</mo>
</msubsup>
<mo>⊕<!-- ⊕ --></mo>
<mi>I</mi>
<mi>V</mi>
<mo>=</mo>
<mn>00</mn>
<mo>⊕<!-- ⊕ --></mo>
<mn>01</mn>
<mo>=</mo>
<mn>01</mn>
<mo>=</mo>
<msub>
<mi>B</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle C_{1}'\oplus IV=00\oplus 01=01=B_{1}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/0a3d589b7ba2b03d7bca981a5caaafe70723b16a.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -1.005ex; width:30.444ex; height:2.843ex;" alt="{\displaystyle C_{1}'\oplus IV=00\oplus 01=01=B_{1}}" loading="lazy"></span></li></ul>
<p>Block 2:
</p>
<ul><li><span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle D_{k}(C_{2})=C_{2}-k=00-11=01=C_{2}'}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>D</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>k</mi>
</mrow>
</msub>
<mo stretchy="false">(</mo>
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
</msub>
<mo stretchy="false">)</mo>
<mo>=</mo>
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
</msub>
<mo>−<!-- − --></mo>
<mi>k</mi>
<mo>=</mo>
<mn>00</mn>
<mo>−<!-- − --></mo>
<mn>11</mn>
<mo>=</mo>
<mn>01</mn>
<mo>=</mo>
<msubsup>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
<mo>′</mo>
</msubsup>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle D_{k}(C_{2})=C_{2}-k=00-11=01=C_{2}'}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/40a210be60458f7ca12801a584765e1bfa682f46.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -1.005ex; width:39.231ex; height:3.009ex;" alt="{\displaystyle D_{k}(C_{2})=C_{2}-k=00-11=01=C_{2}'}" loading="lazy"></span></li>
<li><span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle C_{2}'\oplus C1=01\oplus 11=10=B_{2}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msubsup>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
<mo>′</mo>
</msubsup>
<mo>⊕<!-- ⊕ --></mo>
<mi>C</mi>
<mn>1</mn>
<mo>=</mo>
<mn>01</mn>
<mo>⊕<!-- ⊕ --></mo>
<mn>11</mn>
<mo>=</mo>
<mn>10</mn>
<mo>=</mo>
<msub>
<mi>B</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle C_{2}'\oplus C1=01\oplus 11=10=B_{2}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/f8b7c6dadbddade141dc42e6d8906b05b47740e8.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -1.005ex; width:30.414ex; height:2.843ex;" alt="{\displaystyle C_{2}'\oplus C1=01\oplus 11=10=B_{2}}" loading="lazy"></span></li></ul>
<p>Klartext:
</p>
<ul><li><span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle B_{1}B_{2}=0110}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>B</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
</msub>
<msub>
<mi>B</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
</msub>
<mo>=</mo>
<mn>0110</mn>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle B_{1}B_{2}=0110}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/e144c1eac28124f79714a5513aff69db488952a2.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:13.385ex; height:2.509ex;" alt="{\displaystyle B_{1}B_{2}=0110}" loading="lazy"></span></li></ul>
<p>Betrachtet man die Entschlüsselung von <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle C_{2}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>2</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle C_{2}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/7ec545f7870665e1028b7492746848d149878808.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.716ex; height:2.509ex;" alt="{\displaystyle C_{2}}" loading="lazy"></span>, sieht man, dass <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle B_{1}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>B</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle B_{1}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/1fa091eb428443c9c5c5fcf32a69d3665c89e00c.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.818ex; height:2.509ex;" alt="{\displaystyle B_{1}}" loading="lazy"></span> dafür nicht benötigt wird, sondern lediglich <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle C_{1}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mn>1</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle C_{1}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/babf569931f1a7b5182b9bec51873c2f5692fbb8.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.716ex; height:2.509ex;" alt="{\displaystyle C_{1}}" loading="lazy"></span>. Generell bedeutet das, dass für eine Entschlüsselung von <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle C_{i}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle C_{i}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/cc49dc02c0ec8c86b67e7d10518ac791eda0bf22.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:2.461ex; height:2.509ex;" alt="{\displaystyle C_{i}}" loading="lazy"></span> nur <span class="mwe-math-element mwe-math-element-inline"><span class="mwe-math-mathml-inline mwe-math-mathml-a11y" style="display: none;"><math xmlns="http://www.w3.org/1998/Math/MathML" alttext="{\displaystyle C_{i-1}}">
<semantics>
<mrow class="MJX-TeXAtom-ORD">
<mstyle displaystyle="true" scriptlevel="0">
<msub>
<mi>C</mi>
<mrow class="MJX-TeXAtom-ORD">
<mi>i</mi>
<mo>−<!-- − --></mo>
<mn>1</mn>
</mrow>
</msub>
</mstyle>
</mrow>
<annotation encoding="application/x-tex">{\displaystyle C_{i-1}}</annotation>
</semantics>
</math></span><img src="./_assets_/eb734a37dd21ce173a46342d1cc64c92/06345a9bc7748c399649cdef52231df3f9095eb3.svg" class="mwe-math-fallback-image-inline mw-invert skin-invert" aria-hidden="true" style="vertical-align: -0.671ex; width:4.562ex; height:2.509ex;" alt="{\displaystyle C_{i-1}}" loading="lazy"></span> benötigt wird. Damit ist eine Parallelisierung des Entschlüsselungsvorgangs möglich.
</p>
<div class="mw-heading mw-heading2"><h2 id="Integritätssicherung_mit_CBC,_CBC-MAC"><span id="Integrit.C3.A4tssicherung_mit_CBC.2C_CBC-MAC"></span>Integritätssicherung mit CBC, CBC-MAC</h2></div>
<p>CBC kann auch zur Integritätssicherung benutzt werden, indem der Initialisierungsvektor auf null gesetzt und der letzte mit CBC verschlüsselte Block als <a href="Message_Authentication_Code" title="Message Authentication Code">MAC</a> (dem sogenannten CBC-MAC oder CBC-Restwert) an die ursprüngliche unverschlüsselte Nachricht angehängt und diese samt diesem MAC versandt wird.<sup id="cite_ref-BKR_3-0" class="reference"><a href="#cite_note-BKR-3"><span class="cite-bracket">[</span>3<span class="cite-bracket">]</span></a></sup> Der Empfänger kann mithilfe des CBC-Algorithmus den CBC-MAC der empfangenen Nachricht berechnen und nun vergleichen, ob der gerade selbst berechnete Wert mit dem an der Nachricht angehängten übereinstimmt. Falls eine mit CBC verschlüsselte Nachricht mit einem CBC-MAC gesichert werden soll, darf für die Generierung des CBC-MAC nicht derselbe Schlüssel verwendet werden wie für die Verschlüsselung. Würde derselbe Schlüssel verwendet, so wäre der MAC-Block gleich dem letzten Chiffratblock und ein Angreifer könnte unentdeckt die gesamte Nachricht mit Ausnahme des letzten Blocks verändern.
</p><p>CBC-MAC ist nur für Nachrichten fester Länge sicher. Variiert die Nachrichtenlänge, kann das Verfahren durch <i>Length-Extension</i> angegriffen werden. Ein Angreifer kann aus zwei gültigen Nachricht-MAC-Paaren einen gültigen MAC für eine neue Nachricht (die Konkatenation der beiden Nachrichten) erzeugen. Zwei Modifikationen können diesen Angriff verhindern: Jeder Nachricht kann die Nachrichtenlänge vorangestellt werden oder der MAC-Block wird zusätzlich mit einem zweiten Schlüssel verschlüsselt.
</p>
<div class="mw-heading mw-heading2"><h2 id="Literatur">Literatur</h2></div>
<ul><li>Reinhard Wobst: <cite style="font-style:italic">Abenteuer Kryptologie. Methoden, Risiken und Nutzen der Datenverschlüsselung.</cite> 2., überarbeitete Auflage. Addison-Wesley Longman, Bonn u. a. 1998, ISBN 3-8273-1413-5.<span class="Z3988" title="ctx_ver=Z39.88-2004&rft_val_fmt=info%3Aofi%2Ffmt%3Akev%3Amtx%3Abook&rfr_id=info:sid/de.wikipedia.org:Cipher+Block+Chaining+Mode&rft.au=Reinhard+Wobst&rft.btitle=Abenteuer+Kryptologie.+Methoden%2C+Risiken+und+Nutzen+der+Datenverschl%C3%BCsselung.&rft.date=1998&rft.edition=2.%2C+%C3%BCberarbeitete+Auflage&rft.genre=book&rft.isbn=3827314135&rft.place=Bonn+u.+a.&rft.pub=Addison-Wesley+Longman" style="display:none"> </span></li></ul>
<div class="mw-heading mw-heading2"><h2 id="Einzelnachweise">Einzelnachweise</h2></div>
<ol class="references">
<li id="cite_note-1"><span class="mw-cite-backlink"><a href="#cite_ref-1">↑</a></span> <span class="reference-text">William F. Ehrsam, Carl H. W. Meyer, John L. Smith, Walter L. Tuchman, "Message verification and transmission error detection by block chaining", US-Patent 4074066, 1976</span>
</li>
<li id="cite_note-2"><span class="mw-cite-backlink"><a href="#cite_ref-2">↑</a></span> <span class="reference-text"><span class="cite"><a rel="nofollow" class="external text" href="https://www.jakoblell.com/blog/2013/12/22/practical-malleability-attack-against-cbc-encrypted-luks-partitions/"><i>Practical malleability attack against CBC-Encrypted LUKS partitions | Jakob Lell's Blog.</i></a><span class="Abrufdatum"> Abgerufen am 17. Februar 2022</span> (amerikanisches Englisch).</span><span style="display: none;" class="Z3988" title="ctx_ver=Z39.88-2004&rft_val_fmt=info%3Aofi%2Ffmt%3Akev%3Amtx%3Adc&rfr_id=info%3Asid%2Fde.wikipedia.org%3ACipher+Block+Chaining+Mode&rft.title=Practical+malleability+attack+against+CBC-Encrypted+LUKS+partitions+%7C+Jakob+Lell%27s+Blog&rft.description=Practical+malleability+attack+against+CBC-Encrypted+LUKS+partitions+%7C+Jakob+Lell%27s+Blog&rft.identifier=https%3A%2F%2Fwww.jakoblell.com%2Fblog%2F2013%2F12%2F22%2Fpractical-malleability-attack-against-cbc-encrypted-luks-partitions%2F&rft.language=en-US"> </span></span>
</li>
<li id="cite_note-BKR-3"><span class="mw-cite-backlink"><a href="#cite_ref-BKR_3-0">↑</a></span> <span class="reference-text">
<a href="Mihir_Bellare" title="Mihir Bellare">Mihir Bellare</a>, Joe Kiliany, Phillip Rogaway: <cite style="font-style:italic">The Security of the Cipher Block Chaining Message Authentication Code</cite>. In: <cite style="font-style:italic">Journal of Computer and System Science</cite>. <span style="white-space:nowrap">Band<span style="display:inline-block;width:.2em"> </span>61</span>, <span style="white-space:nowrap">Nr.<span style="display:inline-block;width:.2em"> </span>3</span>, 2000, <span style="white-space:nowrap">S.<span style="display:inline-block;width:.2em"> </span>362–399</span> (<style data-mw-deduplicate="TemplateStyles:r261891140">
/* start https://de.wikipedia.org/ */
.mw-parser-output .webarchiv-memento a{color:inherit}
/* end https://de.wikipedia.org/ */
</style><a rel="nofollow" class="external text" href="https://web.archive.org/web/20120205061813/http://www.cs.ucdavis.edu/research/tech-reports/1997/CSE-97-15.pdf">cs.ucdavis.edu</a> (<span class="webarchiv-memento"><a href="Webarchivierung#Begrifflichkeiten" title="Webarchivierung">Memento</a></span> vom 5. Februar 2012 im <i><a href="Internet_Archive" title="Internet Archive">Internet Archive</a></i>) [PDF; <span style="white-space:nowrap">466<span style="display:inline-block;width:.2em"> </span>kB</span>]).<span class="Z3988" title="ctx_ver=Z39.88-2004&rft_val_fmt=info%3Aofi%2Ffmt%3Akev%3Amtx%3Ajournal&rfr_id=info:sid/de.wikipedia.org:Cipher+Block+Chaining+Mode&rft.atitle=The+Security+of+the+Cipher+Block+Chaining+Message+Authentication+Code&rft.au=Mihir+Bellare%2C+Joe+Kiliany%2C+Phillip+Rogaway&rft.date=2000&rft.genre=journal&rft.issue=3&rft.jtitle=Journal+of+Computer+and+System+Science&rft.pages=362-399&rft.volume=61" style="display:none"> </span></span>
</li>
</ol>
<style data-mw-deduplicate="TemplateStyles:r260755238">
/* start https://de.wikipedia.org/ */
.mw-parser-output div.klappleiste{border:1px solid var(--dewiki-rahmenfarbe1);clear:both;font-size:95%;box-sizing:border-box;margin-top:1.5em;padding:2px}.mw-parser-output div.klappleiste:after{clear:both;content:"";display:block}.mw-parser-output div.klappleiste-bild{float:left;padding:2px}.mw-parser-output div.klappleiste-kopf{background:var(--dewiki-hintergrundfarbe5);color:var(--color-base,#202122);text-align:center;font-weight:bold}.mw-parser-output div.klappleiste.mw-collapsed .klappleiste-bild{display:none}.mw-parser-output div.klappleiste+div.klappleiste,.mw-parser-output div.klappleiste+link+div.klappleiste,.mw-parser-output div.klappleiste+link+link+div.klappleiste,.mw-parser-output div.klappleiste+link+style+div.klappleiste,.mw-parser-output div.klappleiste+style+div.klappleiste,.mw-parser-output div.klappleiste+style+style+div.klappleiste,.mw-parser-output div.klappleiste+style+link+div.klappleiste{margin-top:-1px}@media screen{html.skin-theme-clientpref-night .mw-parser-output .klappleiste-bild span[typeof="mw:File"]:not(.skin-invert-image) img{background-color:#c8ccd1}}@media screen and (prefers-color-scheme:dark){html.skin-theme-clientpref-os .mw-parser-output .klappleiste-bild span[typeof="mw:File"]:not(.skin-invert-image) img{background-color:#c8ccd1}}
/* end https://de.wikipedia.org/ */
</style>
<div class="klappleiste mw-collapsible navileiste navigation-not-searchable center" role="navigation">
<div class="klappleiste-kopf"><a href="Betriebsmodus_(Kryptographie)" title="Betriebsmodus (Kryptographie)">Betriebsmodi von Blockchiffren</a></div>
<div class="klappleiste-inhalt mw-collapsible-content">
<p><i>Ohne Authentifizierung:</i>
<a href="Electronic_Code_Book_Mode" title="Electronic Code Book Mode">ECB</a> •
<a class="mw-selflink selflink">CBC</a> •
<a href="Cipher_Feedback_Mode" title="Cipher Feedback Mode">CFB</a> •
<a href="Output_Feedback_Mode" title="Output Feedback Mode">OFB</a> •
<a href="Counter_Mode" title="Counter Mode">CTR</a> •
<a href="XTS-AES" title="XTS-AES">XTS</a>
</p><p><i>Mit Authentifizierung:</i>
<a href="CCM-Modus" title="CCM-Modus">CCM</a> •
<a href="Galois/Counter_Mode" title="Galois/Counter Mode">GCM</a> •
<a href="EAX-Modus" title="EAX-Modus">EAX</a>
</p>
</div></div></div><!--htdig_noindex--><div><div class="zim-footer">
Dieser Artikel wurde von <a class="external text" title="Zuletzt bearbeitet am 2025-11-23" href="https://de.wikipedia.org/wiki/?title=Cipher_Block_Chaining_Mode&oldid=261783572">Wikipedia</a> herausgegeben. Der Text ist unter <a class="external text" href="https://creativecommons.org/licenses/by-sa/4.0/deed.de">Creative Commons Attribution-Share Alike 4.0</a> verfügbar, sofern nicht anders angegeben. Für die Mediendateien können zusätzliche Bedingungen gelten.
</div>
</div><!--/htdig_noindex--></div>
</div>
</main>
</div>
</div>
</div>
<script src="./_webp_/webpHandler.js"></script>
</body></html>